package com.hyb.service.impl;

import com.hyb.mapper.InfoMapper;
import com.hyb.pojo.Info;
import com.hyb.service.InfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class InfoServiceImpl implements InfoService {
    @Autowired
    InfoMapper infoMapper;
    @Override
    public List<Info> getAll(Map map) {
        return infoMapper.selectAll(map);
    }

    @Override
    public Info getById(int i_id) {
        return infoMapper.selectById(i_id);
    }

    @Override
    public void deleteById(int i_id) {
        infoMapper.deleteById(i_id);
    }

    @Override
    public void addAll(Info info) {
        infoMapper.addAll(info);
    }

    @Override
    public void updateById(Info info) {
        infoMapper.updateById(info);
    }
}
